﻿layui.define(['form'], function (exports) {
    var form = layui.form();
    form.on('select(catId1)', function (data) {
        $('#searchForm').submit();
    });
    form.on('select(catId2)', function (data) {
        $('#searchForm').submit();
    });
    form.on('select(catId3)', function (data) {
        $('#searchForm').submit();
    });
    form.on('select(state)', function (data) {
        $('#searchForm').submit();
    });
    form.on('checkbox', function (data) {
        if ($('#kw').val() != "") {
            $('#searchForm').submit();
        }
    });
    $("#kw").keydown(function (e) {
        if (e.keyCode == 13)
            $('#searchForm').submit();
    })
    exports('article/index', {});
});